package com.ruoyi.purchase.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.purchase.domain.Type;
import com.ruoyi.purchase.service.TypeService;
import com.ruoyi.purchase.mapper.TypeMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author lenovo
* @description 针对表【po_type】的数据库操作Service实现
* @createDate 2022-01-07 14:49:37
*/
@Service
public class TypeServiceImpl extends ServiceImpl<TypeMapper, Type>
    implements TypeService{

    @Autowired
    private TypeMapper typeMapper;

    @Override
    public List<Type> queryList(Type type) {
        return typeMapper.findAllType(type);
    }

    @Override
    public int changeStatus(Type type) {
        return typeMapper.updateUser(type);
    }

    @Override
    public Type selectTypeById(Integer typeId) {
        return typeMapper.selectTypeById(typeId);
    }

    @Override
    public List<Type> findAllType(Type type) {
        return typeMapper.findAllType(type);
    }
}




